/**
 * Project Name:springlearn
 * File Name:TemplateMessage.java
 * Package Name:com.jing.web.util.vrv
 * Date:2016年4月7日上午9:53:46
 * Copyright (c) 2016, chenzhou1025@126.com All Rights Reserved.
 */

package com.vrv.app.cyberspace.common.ddio;

import com.vrv.app.cyberspace.common.utils.ToolUtil;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * ClassName:TemplateMessage <br/>
 * Function: TODO ADD FUNCTION. <br/>
 * Reason:	 TODO ADD REASON. <br/>
 * Date:     2016年4月7日 上午9:53:46 <br/>
 *
 * @author bxy-jing
 * @see
 * @since JDK 1.6
 */
public class TemplateMessage {
    private String sendUserID;
    private String title;
    private String titleColor;
    private String titleBgColor;
    private String creator;
    private String type;
    private String content;
    private String detailUrl;
    private String toUsers;
    private List<Map<String, String>> fields;
    private String status;
    private String statusColor;
    private String chatScene;

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getTitleColor() {
        return titleColor;
    }

    public void setTitleColor(String titleColor) {
        this.titleColor = titleColor;
    }

    public String getTitleBgColor() {
        return titleBgColor;
    }

    public void setTitleBgColor(String titleBgColor) {
        this.titleBgColor = titleBgColor;
    }

    public String getCreator() {
        return creator;
    }

    public void setCreator(String creator) {
        this.creator = creator;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getDetailUrl() {
        return detailUrl;
    }

    public void setDetailUrl(String detailUrl) {
        this.detailUrl = detailUrl;
    }

    public String getToUsers() {
        return toUsers;
    }

    public void setToUsers(String toUsers) {
        this.toUsers = toUsers;
    }

    public String getSendUserID() {
        return sendUserID;
    }

    public void setSendUserID(String sendUserID) {
        this.sendUserID = sendUserID;
    }

    public List<Map<String, String>> getFields() {
        return fields;
    }

    public void setFields(List<Map<String, String>> fields) {
        this.fields = fields;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getStatusColor() {
        return statusColor;
    }

    public void setStatusColor(String statusColor) {
        this.statusColor = statusColor;
    }

    public String getChatScene() {
        return chatScene;
    }

    public void setChatScene(String chatScene) {
        this.chatScene = chatScene;
    }

    private static TemplateMessage tm;

    public static TemplateMessage createOne(String sender, String title, String creator, String content, String detailUrl, String toUsers) {
        if (tm == null) {
            tm = new TemplateMessage();
        }
        tm.setSendUserID(sender);
        tm.setTitle(title);
        tm.setTitleColor("#FFFFFF");
        tm.setTitleBgColor("#4395FF");
        tm.setType("1");
        tm.setCreator(creator);
        tm.setContent(content);
        tm.setDetailUrl(detailUrl);
        tm.setToUsers(toUsers);
        return tm;
    }
}

